<?php include('brand_header.php');?>
<!--主体内容-->
<div class="main brand_activity">
	<div class="activity_left">
    	<img src="<?php echo $huodonghdp[0]['image'];?>" />
        <h1><?php echo $huodonghdp[0]['title'];?></h1>
        <span style="max-height:145px;">开始时间：<?php echo $huodonghdp[0]['fromt'];?><br />
		结束时间<?php echo $huodonghdp[0]['tot'];?><br />
		地点<?php echo $huodonghdp[0]['address'];?><br />
		发起人：<?php echo $huodonghdp[0]['postman'];?><br />
		<?php echo $huodonghdp[0]['content'];?></span>
		<span><a href="###">参加活动</a></span>
    </div>
	<div class="activity_left" style="display:none;">
    	<img src="<?php echo $huodonghdp[1]['image'];?>" />
        <h1><?php echo $huodonghdp[1]['title'];?></h1>
        <span style="max-height:145px;">开始时间：<?php echo $huodonghdp[1]['fromt'];?><br />
		结束时间<?php echo $huodonghdp[1]['tot'];?><br />
		地点<?php echo $huodonghdp[1]['address'];?><br />
		发起人：<?php echo $huodonghdp[1]['postman'];?><br />
		<?php echo $huodonghdp[1]['content'];?></span>
		<span><a href="###">参加活动</a></span>
    </div>
	<div class="activity_left" style="display:none;">
    	<img src="<?php echo $huodonghdp[2]['image'];?>" />
        <h1><?php echo $huodonghdp[2]['title'];?></h1>
        <span style="max-height:145px;">开始时间：<?php echo $huodonghdp[2]['fromt'];?><br />
		结束时间<?php echo $huodonghdp[2]['tot'];?><br />
		地点<?php echo $huodonghdp[2]['address'];?><br />
		发起人：<?php echo $huodonghdp[2]['postman'];?><br />
		<?php echo $huodonghdp[2]['content'];?></span>
		<span><a href="###">参加活动</a></span>
    </div>
	<div class="activity_right">
    	<dl class="this">
        	<dt><img src="<?php echo $huodonghdp[0]['image'];?>" /></dt>
            <dd><span><?php echo $huodonghdp[0]['title'];?></span><?php echo $huodonghdp[0]['content'];?></dd>
        </dl>
    	<dl>
        	<dt><img src="<?php echo $huodonghdp[1]['image'];?>" /></dt>
            <dd><span><?php echo $huodonghdp[1]['title'];?></span><?php echo $huodonghdp[1]['content'];?></dd>
        </dl>
    	<dl>
        	<dt><img src="<?php echo $huodonghdp[2]['image'];?>" /></dt>
            <dd><span><?php echo $huodonghdp[2]['title'];?></span><?php echo $huodonghdp[2]['content'];?></dd>
        </dl>
    </div>
	<div class="float_both"></div>
</div>
<div class="main brand_activity mt20">
	<div class="activity_title">
		<a id="show_last" href="#" class="on">最新活动</a><a id="show_atme" href="#">我参加的活动</a>
    </div>
    <div class="float_both"></div>
    <div class="activity_list">
		<!--最新活动-->
		<div id="activity_last">
		<?php foreach($nohuodongs as $nohuodong){?>
			<dl>
				<dt><img src="<?php echo $nohuodong['image'];?>" /></dt>
				<dd><span><?php echo $nohuodong['title'];?></span>
				  <?php echo $nohuodong['content'];?>
					<a href="index.php?mod=event&code=detail&id=<?php echo $nohuodong['id']; ?>">我要参加</a></dd>
			</dl>
		<?php }?>
			<div class="float_both"></div>
		</div>
		
		<!--我参加的活动-->
		<div id="activity_atme" style="display:none;">
		<?php foreach($myhuodongs as $myhuodong){?>
			<dl>
				<dt><img src="<?php echo $myhuodong['image'];?>" /></dt>
				<dd><span><?php echo $myhuodong['title'];?></span>
				  <?php echo $myhuodong['content'];?>
					<a href="index.php?mod=event&code=detail&id=<?php echo $myhuodong['id']; ?>">查看详情</a>
			</dl>
		<?php }?>
			<div class="float_both"></div>
		</div>
	</div>
</div>
<script type="text/javascript" >

$(function(){
	$(".activity_right dl").click(function(){
		$(".activity_right dl").removeClass("this");
		$(this).addClass("this");
		var e = $(".activity_right dl").index(this);
		$(".activity_left").hide();
		$(".activity_left").eq(e).show();
	});
	
	$("#show_last").click(function(){
		$("#show_last").addClass("on");
		$("#show_atme").removeClass("on");
		$("#activity_last").slideDown();
		$("#activity_atme").slideUp();
	});
	$("#show_atme").click(function(){
		$("#show_last").removeClass("on");
		$("#show_atme").addClass("on");
		$("#activity_last").slideUp();
		$("#activity_atme").slideDown();
	});
})
</script>
<!--底部-->
<?php include_once 'brand_footer.php' ;?>
